package cl.zeke.cursos.jsf2spring3jpa2.negocio.services;

import cl.zeke.cursos.jsf2spring3jpa2.dao.PerfilDao;
import cl.zeke.cursos.jsf2spring3jpa2.negocio.entities.Perfil;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Scope;
import org.springframework.context.annotation.ScopedProxyMode;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

/**
 *
 * @author eduardo
 */
@Service
@Scope(proxyMode = ScopedProxyMode.INTERFACES)
public class ComunesServiceImpl implements ComunesService {
    
    @Autowired
    private PerfilDao perfilDao;
    
    @Transactional(readOnly = true)
    public List<Perfil> traerTodosLosPerfiles() {
        return perfilDao.traerTodos();
    }
    
}
